package site.jlopen.kuscia.model.task;

import java.util.ArrayList;
import java.util.List;

import lombok.Getter;
import lombok.Setter;
import lombok.ToString;

@Getter
@Setter
@ToString
public class TaskStatusResponeVo {
	
	String taskId;
	
	String state;
	
	String errMsg;
	
	String config;
	
	List<TaskStatuPartie> taskStatuParties;

	public TaskStatusResponeVo(String taskId, String state, String errMsg, String config) {
		super();
		this.taskId = taskId;
		this.state = state;
		this.errMsg = errMsg;
		this.config = config;
	}
	
	public TaskStatusResponeVo addPartie(TaskStatuPartie taskStatuPartie) {
		if(null == taskStatuParties) {
			taskStatuParties = new ArrayList<TaskStatuPartie>();
		}
		taskStatuParties.add(taskStatuPartie);
		return this;
	}
}
